This file is part of the supplementary material of the manuscript: Didino, D., Brandtner, M., & Knops, A. (2021). No influence of masked priming on the multiplication fact retrieval in a result verification task.
This script reports the analysis for experiment 2.
Dataset loaded: exp2_data.rds (data of result verification task)
Load libraries, my functions (my_functions folder) and data (data/processed folder):
library('ggpubr')
#> Loading required package: ggplot2
library('here')
#> here() starts at D:/mult_prime
library('kableExtra')
# library('knitr')
library('plotly')
#>
#> Attaching package: 'plotly'
#> The following object is masked from 'package:ggplot2':
#>
#> last_plot
#> The following object is masked from 'package:stats':
#>
#> filter
#> The following object is masked from 'package:graphics':
#>
#> layout
library('ggridges')
library('tidyverse')
#> -- Attaching packages --------------------------------------- tidyverse 1.3.1 --
#> v tibble 3.1.0 v dplyr 1.0.5
#> v tidyr 1.1.3 v stringr 1.4.0
#> v readr 1.4.0 v forcats 0.5.1
#> v purrr 0.3.4
#> -- Conflicts ------------------------------------------ tidyverse_conflicts() --
#> x dplyr::filter() masks plotly::filter(), stats::filter()
#> x dplyr::group_rows() masks kableExtra::group_rows()
#> x dplyr::lag() masks stats::lag()
library('BayesFactor')
#> Loading required package: coda
#> Loading required package: Matrix
#>
#> Attaching package: 'Matrix'
#> The following objects are masked from 'package:tidyr':
#>
#> expand, pack, unpack
#> ************
#> Welcome to BayesFactor 0.9.12-4.2. If you have questions, please contact Richard Morey (richarddmorey@gmail.com).
#>
#> Type BFManual() to open the manual.
#> ************
# Load my functions
source(here('funcs', 'load_my_functions.R'))
# Load data
exp2 <- readRDS(here('data', 'processed', 'exp2_data.rds'))
Exclude outliers
exp2 <-
exp2 %>%
filter(outlier == FALSE)
RTs distribution across prime conditions:
plot_1 <-
exp2 %>%
ggplot(aes(RT, fill = prime_cond)) +
geom_density(alpha = 0.6) +
facet_wrap(~ SOA + problem_size, ncol = 2) +
theme(panel.spacing = unit(1, "cm"))
ggplotly(plot_1)
Comparison between the distribution of the RTs of the neutral condition and the other conditions. The neutral condition is replicated next to each condition to facilitate the comparison.
exp2_rainplot <-
exp2 %>%
group_by(SOA) %>%
group_nest() %>%
mutate(
by_SOA = map(
data,
~return_means(RT, c('problem_size', 'sj', 'prime_cond'), .) %>%
return_df_plot(.,
problem_size,
prime_cond,
'neutral')
)
) %>%
unnest(by_SOA)
#> `summarise()` has grouped output by 'problem_size', 'sj'. You can override using the `.groups` argument.
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> `summarise()` has grouped output by 'problem_size', 'sj'. You can override using the `.groups` argument.
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> `summarise()` has grouped output by 'problem_size', 'sj'. You can override using the `.groups` argument.
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
#> Joining, by = c("sj", "DV", "neutral")
# Set H0/H1 position
segs <-
tribble(
~SOA, ~problem_size, ~cond, ~neutral, ~lab, ~ys,
'SOA_070', 'Large', 'neigh_con', 'Neutral', 'H0', 1000,
'SOA_070', 'Large', 'unrel_con', 'Neutral', 'H0', 1000,
'SOA_070', 'Small', 'neigh_con', 'Neutral', 'H0', 1000,
'SOA_070', 'Small', 'unrel_con', 'Neutral', 'H0', 1000,
'SOA_120', 'Large', 'neigh_con', 'Neutral', 'H0', 1000,
'SOA_120', 'Large', 'neigh_inc', 'Neutral', 'H1', 1000,
'SOA_120', 'Large', 'unrel_inc', 'Neutral', 'H1', 1000,
'SOA_120', 'Small', 'neigh_con', 'Neutral', 'H0', 1000,
'SOA_120', 'Small', 'unrel_con', 'Neutral', 'H0', 1000,
'SOA_120', 'Small', 'unrel_inc', 'Neutral', 'H0', 1000,
'SOA_170', 'Large', 'neigh_con', 'Neutral', 'H0', 1000,
'SOA_170', 'Large', 'unrel_con', 'Neutral', 'H0', 1000,
'SOA_170', 'Small', 'neigh_con', 'Neutral', 'H1', 1000,
'SOA_170', 'Small', 'unrel_con', 'Neutral', 'H1', 1000,
'SOA_170', 'Small', 'unrel_inc', 'Neutral', 'H1', 1000)
# Plot
prime_plot <-
list(exp2_RT_distr =
exp2_rainplot %>%
mutate(
neutral = if_else(neutral == 'neutral', 'Neutral', 'Other'),
problem_size = if_else(problem_size == 'large', 'Large', 'Small')
) %>%
ggplot(aes(x = cond, y = DV, fill = neutral)) +
geom_flat_violin(aes(fill = neutral),
position = position_nudge(x = 0.18, y = 0),
adjust = 1.5,
trim = FALSE,
alpha = .5,
colour = NA) +
geom_point(aes(x = as.numeric(factor(cond)) - 0.23, y = DV, colour = neutral),
position = position_jitter(width = 0.05, height = 0),
size = 1,
shape = 20) +
geom_boxplot(aes(x = cond, y = DV, fill = neutral),
outlier.shape = NA,
alpha = 0.5,
width = 0.3,
colour = 'black') +
geom_text(data = segs,
aes(x = cond, y = ys, label = lab),
size = 3.5) +
geom_vline(xintercept = c(c(0:3) + 1.65),
linetype = 'solid',
color = 'grey80',
size = 0.3) +
# scale_colour_brewer(palette = 'Dark2') +
# scale_fill_brewer(palette = 'Dark2') +
labs(x = 'Prime condition', y = 'RTs') +
facet_grid(rows = vars(SOA), cols = vars(problem_size)) +
theme(
#panel.grid.major = element_blank(),
#panel.grid.minor = element_blank(),
panel.background = element_blank(),
panel.grid.major.y = element_line(colour = 'grey90'),
panel.grid.minor.y = element_line(colour = 'grey90'),
panel.grid.major.x = element_blank(),
panel.grid.minor.x = element_blank(),
legend.title = element_blank(),
strip.background = element_blank(),
text = element_text(size = 15),
axis.text = element_text(size = 12, colour = 'black'),
axis.text.x = element_text(angle = 45, hjust = 1),
# axis.title = element_text(size = 14),
panel.border = element_rect(colour = 'black', fill = NA, size = 0.5)
)
)
# show plot
prime_plot$exp2_RT_distr
# Plot - Black and white version
prime_plot$exp2_RT_distr_bw <-
exp2_rainplot %>%
mutate(
neutral = if_else(neutral == 'neutral', 'Neutral', 'Other'),
problem_size = if_else(problem_size == 'large', 'Large', 'Small')
) %>%
ggplot(aes(x = cond, y = DV, fill = neutral)) +
geom_flat_violin(position = position_nudge(x = 0.15, y = 0),
adjust = 1.5,
trim = FALSE,
alpha = .5,
colour = 'black') +
geom_point(aes(x = as.numeric(factor(cond)) - 0.2, y = DV),
position = position_jitter(width = 0.05, height = 0),
size = 1,
shape = 21) +
geom_boxplot(outlier.shape = NA,
alpha = 0.5,
width = 0.25) +
geom_text(data = segs,
aes(x = cond, y = ys, label = lab),
size = 3.5) +
geom_vline(xintercept = c(c(0:3) + 1.65),
linetype = 'solid',
color = 'grey80',
size = 0.3) +
scale_fill_manual(values = c('white', 'grey20')) +
scale_color_manual(values = c('white', 'grey20')) +
labs(x = 'Prime condition', y = 'RTs') +
facet_grid(rows = vars(SOA), cols = vars(problem_size)) +
theme(
#panel.grid.major = element_blank(),
#panel.grid.minor = element_blank(),
panel.background = element_blank(),
panel.grid.major.y = element_line(colour = 'grey90'),
panel.grid.minor.y = element_line(colour = 'grey90'),
panel.grid.major.x = element_blank(),
panel.grid.minor.x = element_blank(),
legend.title = element_blank(),
strip.background = element_blank(),
text = element_text(size = 15),
axis.text = element_text(size = 12, colour = 'black'),
axis.text.x = element_text(angle = 45, hjust = 1),
# axis.title = element_text(size = 14),
panel.border = element_rect(colour = 'black', fill = NA, size = 0.5)
)
Bayes factors are computer with the package BayesFactor.
tribble(
~BF, ~Evidence,
'0-3', 'Anectodal',
'3-10', 'Moderate',
'10-30', 'Strong',
'30-100', 'Very_strong',
'>100', 'Decisive') %>%
make_table('Bayes factor interpretation')
| BF | Evidence |
|---|---|
| 0-3 | Anectodal |
| 3-10 | Moderate |
| 10-30 | Strong |
| 30-100 | Very_strong |
| >100 | Decisive |
Compute Bayes factors
exp2_bf <-
exp2 %>%
group_by(SOA) %>%
group_nest() %>%
mutate(
bf_soa = map(
data,
~return_BF_ttest(.,
problem_size,
prime_cond,
'neutral',
RT,
ID = 'sj')
)
) %>%
select(SOA, bf_soa) %>%
unnest(bf_soa) %>%
identity()
exp2_bf
#> # A tibble: 24 x 11
#> SOA problem_size prime_cond.x data.x aggr_data.x prime_cond.y
#> <chr> <chr> <chr> <list<tibble[,> <list> <chr>
#> 1 SOA_0~ large neigh_con [330 x 17] <tibble[,2] [2~ neutral
#> 2 SOA_0~ large neigh_inc [337 x 17] <tibble[,2] [2~ neutral
#> 3 SOA_0~ large unrel_con [341 x 17] <tibble[,2] [2~ neutral
#> 4 SOA_0~ large unrel_inc [342 x 17] <tibble[,2] [2~ neutral
#> 5 SOA_0~ small neigh_con [408 x 17] <tibble[,2] [2~ neutral
#> 6 SOA_0~ small neigh_inc [412 x 17] <tibble[,2] [2~ neutral
#> 7 SOA_0~ small unrel_con [407 x 17] <tibble[,2] [2~ neutral
#> 8 SOA_0~ small unrel_inc [409 x 17] <tibble[,2] [2~ neutral
#> 9 SOA_1~ large neigh_con [338 x 17] <tibble[,2] [2~ neutral
#> 10 SOA_1~ large neigh_inc [346 x 17] <tibble[,2] [2~ neutral
#> # ... with 14 more rows, and 5 more variables: data.y <list<tibble[,17]>>,
#> # aggr_data.y <list>, BF_test <list>, bf <dbl>, error <dbl>
exp2_bf <-
exp2_bf %>%
select(SOA, problem_size, prime_cond.x, bf) %>%
rename(prime_cond = prime_cond.x, BF_10 = bf) %>%
mutate(
BF_01 = 1 / BF_10
)
# # Show results
# exp2_bf %>%
# make_table('Bayes factor')
Calculate statistics for RT
exp2_stats <-
exp2 %>%
return_stats(c('SOA', 'problem_size', 'prime_cond'))
#> `summarise()` has grouped output by 'sj', 'SOA', 'problem_size'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'SOA', 'problem_size'. You can override using the `.groups` argument.
# Add difference between prime means and neutral prime mean
exp2_stats <-
left_join(
exp2_stats,
exp2_stats %>%
filter(prime_cond == 'neutral') %>%
select(SOA, problem_size, Mean) %>%
rename(Diff = Mean)
) %>%
mutate(
Diff = Mean - Diff
)
#> Joining, by = c("SOA", "problem_size")
# # Print results in a file
# exp2_stats %>%
# print_result('exp2_stats_RTs')
#
# # Show the table with the statistics
# exp2_stats %>%
# make_table('Prime type statistics')
Table with RTs mean, standard deviation and standard error (aggregated on subject, condition, and SOA), and Bayes factors:
exp2_table <-
full_join(
exp2_stats %>%
mutate(across(where(is.numeric), ~round(.x, digits = 0))),
exp2_bf %>%
mutate(across(where(is.numeric), ~round(.x, digits = 2))))
#> Joining, by = c("SOA", "problem_size", "prime_cond")
# Print results in a file
exp2_table %>%
# mutate(across(where(is.numeric), ~round(.x, digits = 2))) %>%
print_result('exp2_table')
# Show results
exp2_table %>%
make_table('Table2')
| SOA | problem_size | prime_cond | N_sj | Mean | SD | SE | Diff | BF_10 | BF_01 |
|---|---|---|---|---|---|---|---|---|---|
| SOA_070 | large | neigh_con | 28 | 605 | 105 | 20 | 11 | 0.29 | 3.44 |
| SOA_070 | large | neigh_inc | 28 | 618 | 111 | 21 | 23 | 0.98 | 1.02 |
| SOA_070 | large | neutral | 28 | 594 | 107 | 20 | 0 | NA | NA |
| SOA_070 | large | unrel_con | 28 | 600 | 92 | 17 | 5 | 0.23 | 4.31 |
| SOA_070 | large | unrel_inc | 28 | 611 | 125 | 24 | 17 | 0.34 | 2.90 |
| SOA_070 | small | neigh_con | 28 | 553 | 93 | 18 | -1 | 0.20 | 4.93 |
| SOA_070 | small | neigh_inc | 28 | 571 | 86 | 16 | 17 | 0.73 | 1.36 |
| SOA_070 | small | neutral | 28 | 554 | 88 | 17 | 0 | NA | NA |
| SOA_070 | small | unrel_con | 28 | 563 | 99 | 19 | 8 | 0.27 | 3.65 |
| SOA_070 | small | unrel_inc | 28 | 578 | 112 | 21 | 24 | 1.03 | 0.97 |
| SOA_120 | large | neigh_con | 28 | 592 | 105 | 20 | 10 | 0.29 | 3.43 |
| SOA_120 | large | neigh_inc | 28 | 630 | 119 | 22 | 48 | 191.02 | 0.01 |
| SOA_120 | large | neutral | 28 | 582 | 108 | 20 | 0 | NA | NA |
| SOA_120 | large | unrel_con | 28 | 595 | 126 | 24 | 13 | 0.36 | 2.79 |
| SOA_120 | large | unrel_inc | 28 | 617 | 112 | 21 | 36 | 9.05 | 0.11 |
| SOA_120 | small | neigh_con | 28 | 552 | 103 | 20 | -2 | 0.20 | 4.89 |
| SOA_120 | small | neigh_inc | 28 | 562 | 102 | 19 | 8 | 0.36 | 2.81 |
| SOA_120 | small | neutral | 28 | 554 | 102 | 19 | 0 | NA | NA |
| SOA_120 | small | unrel_con | 28 | 552 | 88 | 17 | -2 | 0.20 | 4.91 |
| SOA_120 | small | unrel_inc | 28 | 564 | 96 | 18 | 10 | 0.27 | 3.66 |
| SOA_170 | large | neigh_con | 28 | 589 | 110 | 21 | 13 | 0.28 | 3.57 |
| SOA_170 | large | neigh_inc | 28 | 601 | 103 | 19 | 25 | 1.50 | 0.67 |
| SOA_170 | large | neutral | 28 | 576 | 106 | 20 | 0 | NA | NA |
| SOA_170 | large | unrel_con | 28 | 582 | 102 | 19 | 5 | 0.22 | 4.63 |
| SOA_170 | large | unrel_inc | 28 | 605 | 108 | 20 | 29 | 1.73 | 0.58 |
| SOA_170 | small | neigh_con | 28 | 562 | 101 | 19 | 32 | 10.72 | 0.09 |
| SOA_170 | small | neigh_inc | 28 | 555 | 96 | 18 | 25 | 2.69 | 0.37 |
| SOA_170 | small | neutral | 28 | 531 | 77 | 15 | 0 | NA | NA |
| SOA_170 | small | unrel_con | 28 | 559 | 103 | 19 | 28 | 4.20 | 0.24 |
| SOA_170 | small | unrel_inc | 28 | 556 | 87 | 17 | 25 | 5.60 | 0.18 |
# Set bar colors ("neutral" is the 4th and the 10th)
bar_colors <- rep(c('gray80', 'gray80', 'gray40', 'gray80', 'gray80'), 6)
# Set asterisk position
segs <-
tribble(
~SOA, ~problem_size, ~prime_cond, ~lab, ~ys,
'SOA_070', 'large', 'neigh_con', 'H0', 520,
'SOA_070', 'large', 'unrel_con', 'H0', 520,
'SOA_070', 'small', 'neigh_con', 'H0', 520,
'SOA_070', 'small', 'unrel_con', 'H0', 520,
'SOA_120', 'large', 'neigh_con', 'H0', 520,
'SOA_120', 'large', 'neigh_inc', 'H1', 520,
'SOA_120', 'large', 'unrel_inc', 'H1', 520,
'SOA_120', 'small', 'neigh_con', 'H0', 520,
'SOA_120', 'small', 'unrel_con', 'H0', 520,
'SOA_120', 'small', 'unrel_inc', 'H0', 520,
'SOA_170', 'large', 'neigh_con', 'H0', 520,
'SOA_170', 'large', 'unrel_con', 'H0', 520,
'SOA_170', 'small', 'neigh_con', 'H1', 520,
'SOA_170', 'small', 'unrel_con', 'H1', 520,
'SOA_170', 'small', 'unrel_inc', 'H1', 520)
# plot prime type
prime_plot$exp2_box <-
exp2_stats %>%
mutate(
prime_cond = factor(
prime_cond,
levels = c('identity', 'neutral', 'neigh_con', 'neigh_inc', 'unrel_con', 'unrel_inc')
)) %>%
ggplot(aes(x = prime_cond, y = Mean, fill = prime_cond)) +
geom_bar(stat = 'identity',
fill = bar_colors,
width = 0.6,
show.legend = FALSE) +
geom_errorbar(
aes(group = prime_cond, ymin = Mean - SE, ymax = Mean + SE),
width = 0.07,
position = position_dodge(0.9)) +
geom_text(data = segs,
aes(x = prime_cond, y = ys, label = lab),
size = 3) +
coord_cartesian(ylim = c(500, 675)) +
labs(x = 'Prime cond', y = 'Mean RTs') +
facet_wrap(~ SOA + problem_size, ncol = 2) +
theme(
#panel.grid.major = element_blank(),
#panel.grid.minor = element_blank(),
panel.background = element_blank(),
panel.grid.major.y = element_line(colour = 'grey90'),
panel.grid.minor.y = element_line(colour = 'grey90'),
panel.grid.major.x = element_blank(),
panel.grid.minor.x = element_blank(),
text = element_text(size = 15),
axis.text = element_text(size = 12, colour = 'black'),
axis.text.x = element_text(angle = 45, hjust = 1),
# axis.title = element_text(size = 14),
panel.border = element_rect(colour = 'black', fill = NA, size = 0.5))
# show plot
prime_plot$exp2_box
# Set asterisk position
segs <-
tribble(
~SOA, ~problem_size, ~prime_cond, ~lab, ~ys,
'SOA_170', 'small', 'neigh_con', '11', 9,
'SOA_120', 'large', 'neigh_inc', '191', 9)
# plot prime type
prime_plot$exp2_bf <-
exp2_bf %>%
mutate(
prime_cond = factor(
prime_cond,
levels = c('neigh_con', 'neigh_inc', 'unrel_con', 'unrel_inc'))
) %>%
ggplot(aes(x = prime_cond, y = BF_10, fill = prime_cond)) +
geom_bar(stat = 'identity',
fill = 'gray80',
width = 0.6,
show.legend = FALSE) +
geom_text(data = segs,
aes(x = prime_cond, y = ys, label = lab),
size = 3) +
geom_hline(yintercept = c(3, 10, 30, 100),
linetype = 'dashed',
color = 'red',
size = 0.5) +
coord_cartesian(ylim = c(0, 10)) +
labs(x = 'Prime cond', y = bquote('Bayes factor (' ~BF[10]~ ')')) +
facet_wrap(~ SOA + problem_size, ncol = 2) +
theme(
#panel.grid.major = element_blank(),
#panel.grid.minor = element_blank(),
panel.background = element_blank(),
panel.grid.major.y = element_line(colour = 'grey90'),
panel.grid.minor.y = element_line(colour = 'grey90'),
panel.grid.major.x = element_blank(),
panel.grid.minor.x = element_blank(),
text = element_text(size = 15),
axis.text = element_text(size = 12, colour = 'black'),
axis.text.x = element_text(angle = 45, hjust = 1),
# axis.title = element_text(size = 14),
panel.border = element_rect(colour = 'black', fill = NA, size = 0.5))
NULL
#> NULL
# show plot
prime_plot$exp2_bf
Calculate the t-tests between neutral prime and other conditions (the results are also saved in the folder results)
# prepare conditions to compare in the t-tests
prime_cond_to_comprare <-
list(c('neigh_con', 'neutral'),
c('neigh_inc', 'neutral'),
c('unrel_con', 'neutral'),
c('unrel_inc', 'neutral'))
# t-tests between prime conditions
exp2_ttests <-
exp2 %>%
group_by(SOA, problem_size) %>%
group_nest() %>%
mutate(
ttests = map(
data,
~return_ttest_2samples(RT,
prime_cond,
prime_cond_to_comprare,
c('sj', 'prime_cond'),
.)
)) %>%
select(SOA, problem_size, ttests) %>%
unnest(ttests) %>%
mutate(
p_adj = p.adjust(p, method = 'holm'),
Sig_adj = p.adjust(p, method = 'holm') < 0.05
)
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
#> `summarise()` has grouped output by 'sj'. You can override using the `.groups` argument.
# Print the results in csv and txt files
exp2_ttests %>%
print_result(., 'exp2_ttests')
# Show the table with the statistics
exp2_ttests %>%
make_table('T-tests for experiment 2')
| SOA | problem_size | var1 | var2 | mean_var1 | mean_var2 | mean_diff | std_error | t | df | p | sig | Cohen_d_z | Hedges_g_av | p_adj | Sig_adj |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| SOA_070 | large | neigh_con | neutral | 604.78 | 594.22 | 10.55 | 11.69 | 0.90 | 27 | 0.37 | FALSE | 0.17 | 0.10 | 1.00 | FALSE |
| SOA_070 | large | neigh_inc | neutral | 617.54 | 594.22 | 23.32 | 12.21 | 1.91 | 27 | 0.07 | FALSE | 0.36 | 0.21 | 1.00 | FALSE |
| SOA_070 | large | unrel_con | neutral | 599.51 | 594.22 | 5.29 | 9.40 | 0.56 | 27 | 0.58 | FALSE | 0.11 | 0.05 | 1.00 | FALSE |
| SOA_070 | large | unrel_inc | neutral | 611.03 | 594.22 | 16.80 | 15.35 | 1.09 | 27 | 0.28 | FALSE | 0.21 | 0.14 | 1.00 | FALSE |
| SOA_070 | small | neigh_con | neutral | 553.29 | 554.46 | -1.18 | 7.50 | -0.16 | 27 | 0.88 | FALSE | 0.03 | 0.01 | 1.00 | FALSE |
| SOA_070 | small | neigh_inc | neutral | 570.98 | 554.46 | 16.52 | 9.61 | 1.72 | 27 | 0.10 | FALSE | 0.32 | 0.19 | 1.00 | FALSE |
| SOA_070 | small | unrel_con | neutral | 562.71 | 554.46 | 8.25 | 9.97 | 0.83 | 27 | 0.42 | FALSE | 0.16 | 0.09 | 1.00 | FALSE |
| SOA_070 | small | unrel_inc | neutral | 578.13 | 554.46 | 23.66 | 12.17 | 1.94 | 27 | 0.06 | FALSE | 0.37 | 0.23 | 1.00 | FALSE |
| SOA_120 | large | neigh_con | neutral | 592.27 | 581.92 | 10.35 | 11.39 | 0.91 | 27 | 0.37 | FALSE | 0.17 | 0.10 | 1.00 | FALSE |
| SOA_120 | large | neigh_inc | neutral | 629.72 | 581.92 | 47.80 | 10.80 | 4.42 | 27 | 0.00 | TRUE | 0.84 | 0.42 | 0.00 | TRUE |
| SOA_120 | large | unrel_con | neutral | 595.07 | 581.92 | 13.15 | 11.58 | 1.14 | 27 | 0.27 | FALSE | 0.21 | 0.11 | 1.00 | FALSE |
| SOA_120 | large | unrel_inc | neutral | 617.49 | 581.92 | 35.58 | 11.49 | 3.10 | 27 | 0.00 | TRUE | 0.59 | 0.32 | 0.10 | FALSE |
| SOA_120 | small | neigh_con | neutral | 552.22 | 554.25 | -2.03 | 9.62 | -0.21 | 27 | 0.83 | FALSE | 0.04 | 0.02 | 1.00 | FALSE |
| SOA_120 | small | neigh_inc | neutral | 562.47 | 554.25 | 8.23 | 7.30 | 1.13 | 27 | 0.27 | FALSE | 0.21 | 0.08 | 1.00 | FALSE |
| SOA_120 | small | unrel_con | neutral | 552.09 | 554.25 | -2.16 | 11.33 | -0.19 | 27 | 0.85 | FALSE | 0.04 | 0.02 | 1.00 | FALSE |
| SOA_120 | small | unrel_inc | neutral | 564.01 | 554.25 | 9.76 | 11.83 | 0.83 | 27 | 0.42 | FALSE | 0.16 | 0.10 | 1.00 | FALSE |
| SOA_170 | large | neigh_con | neutral | 588.99 | 576.41 | 12.58 | 14.67 | 0.86 | 27 | 0.40 | FALSE | 0.16 | 0.11 | 1.00 | FALSE |
| SOA_170 | large | neigh_inc | neutral | 601.34 | 576.41 | 24.93 | 11.48 | 2.17 | 27 | 0.04 | TRUE | 0.41 | 0.24 | 0.66 | FALSE |
| SOA_170 | large | unrel_con | neutral | 581.79 | 576.41 | 5.39 | 13.49 | 0.40 | 27 | 0.69 | FALSE | 0.08 | 0.05 | 1.00 | FALSE |
| SOA_170 | large | unrel_inc | neutral | 605.30 | 576.41 | 28.90 | 12.82 | 2.25 | 27 | 0.03 | TRUE | 0.43 | 0.27 | 0.59 | FALSE |
| SOA_170 | small | neigh_con | neutral | 562.31 | 530.80 | 31.51 | 9.92 | 3.18 | 27 | 0.00 | TRUE | 0.60 | 0.35 | 0.09 | FALSE |
| SOA_170 | small | neigh_inc | neutral | 555.34 | 530.80 | 24.55 | 9.84 | 2.49 | 27 | 0.02 | TRUE | 0.47 | 0.28 | 0.36 | FALSE |
| SOA_170 | small | unrel_con | neutral | 558.97 | 530.80 | 28.17 | 10.34 | 2.72 | 27 | 0.01 | TRUE | 0.51 | 0.31 | 0.22 | FALSE |
| SOA_170 | small | unrel_inc | neutral | 556.21 | 530.80 | 25.41 | 8.86 | 2.87 | 27 | 0.01 | TRUE | 0.54 | 0.30 | 0.17 | FALSE |
ggarrange(prime_plot$exp2_RT_distr)
ggsave(here('figures', 'exp2_RTs_distr.tiff'),
width = 9,
height = 7,
dpi = 150) # or dpi = 300
ggarrange(prime_plot$exp2_RT_distr_bw)
ggsave(here('figures', 'exp2_RTs_distr_bw.tiff'),
width = 9,
height = 7,
dpi = 150) # or dpi = 300
ggarrange(prime_plot$exp2_box)
ggsave(here('figures', 'exp2_RTs.tiff'),
width = 8,
height = 6,
dpi = 150) # or dpi = 300
ggarrange(prime_plot$exp2_bf)
ggsave(here('figures', 'exp2_BF.tiff'),
width = 8,
height = 6,
dpi = 150) # or dpi = 300
xfun::session_info()
#> R version 4.0.5 (2021-03-31)
#> Platform: x86_64-w64-mingw32/x64 (64-bit)
#> Running under: Windows 10 x64 (build 19044)
#>
#> Locale:
#> LC_COLLATE=English_United Kingdom.1252
#> LC_CTYPE=English_United Kingdom.1252
#> LC_MONETARY=English_United Kingdom.1252
#> LC_NUMERIC=C
#> LC_TIME=English_United Kingdom.1252
#>
#> Package version:
#> abind_1.4-5 askpass_1.1 assertthat_0.2.1
#> backports_1.2.1 base64enc_0.1.3 BayesFactor_0.9.12-4.2
#> BH_1.75.0.0 blob_1.2.1 boot_1.3.27
#> broom_0.7.6 bslib_0.2.4 callr_3.6.0
#> car_3.0-10 carData_3.0-4 cellranger_1.1.0
#> cli_2.4.0 clipr_0.7.1 coda_0.19-4
#> colorspace_2.0-0 compiler_4.0.5 conquer_1.0.2
#> contfrac_1.1.12 corrplot_0.84 cowplot_1.1.1
#> cpp11_0.2.7 crayon_1.4.1 crosstalk_1.1.1
#> curl_4.3 data.table_1.14.0 DBI_1.1.1
#> dbplyr_2.1.1 deSolve_1.28 digest_0.6.27
#> dplyr_1.0.5 dtplyr_1.1.0 ellipsis_0.3.1
#> elliptic_1.4.0 evaluate_0.14 fansi_0.4.2
#> farver_2.1.0 forcats_0.5.1 foreign_0.8-81
#> fs_1.5.0 gargle_1.1.0 generics_0.1.0
#> ggplot2_3.3.5 ggpubr_0.4.0 ggrepel_0.9.1
#> ggridges_0.5.3 ggsci_2.9 ggsignif_0.6.1
#> glue_1.4.2 googledrive_1.0.1 googlesheets4_0.3.0
#> graphics_4.0.5 grDevices_4.0.5 grid_4.0.5
#> gridExtra_2.3 gtable_0.3.0 gtools_3.8.2
#> haven_2.3.1 here_1.0.1 highr_0.8
#> hms_1.0.0 htmltools_0.5.1.1 htmlwidgets_1.5.3
#> httr_1.4.2 hypergeo_1.2.13 ids_1.0.1
#> isoband_0.2.4 jquerylib_0.1.3 jsonlite_1.7.2
#> kableExtra_1.3.4 knitr_1.33 labeling_0.4.2
#> later_1.1.0.1 lattice_0.20-41 lazyeval_0.2.2
#> lifecycle_1.0.0 lme4_1.1.26 lubridate_1.7.10
#> magrittr_2.0.1 maptools_1.1.1 markdown_1.1
#> MASS_7.3.53.1 Matrix_1.3-2 MatrixModels_0.5-0
#> matrixStats_0.58.0 methods_4.0.5 mgcv_1.8.34
#> mime_0.10 minqa_1.2.4 modelr_0.1.8
#> munsell_0.5.0 mvtnorm_1.1-1 nlme_3.1.152
#> nloptr_1.2.2.2 nnet_7.3.15 numDeriv_2016.8.1.1
#> openssl_1.4.3 openxlsx_4.2.3 parallel_4.0.5
#> pbapply_1.4-3 pbkrtest_0.5.1 pillar_1.6.0
#> pkgconfig_2.0.3 plotly_4.9.3 plyr_1.8.6
#> polynom_1.4.0 prettyunits_1.1.1 processx_3.5.1
#> progress_1.2.2 promises_1.2.0.1 ps_1.6.0
#> purrr_0.3.4 quantreg_5.85 R6_2.5.0
#> rappdirs_0.3.3 RColorBrewer_1.1.2 Rcpp_1.0.6
#> RcppArmadillo_0.10.2.2.0 RcppEigen_0.3.3.9.1 readr_1.4.0
#> readxl_1.3.1 rematch_1.0.1 rematch2_2.1.2
#> reprex_2.0.0 rio_0.5.26 rlang_0.4.10
#> rmarkdown_2.7 rprojroot_2.0.2 rstatix_0.7.0
#> rstudioapi_0.13 rvest_1.0.0 sass_0.3.1
#> scales_1.1.1 selectr_0.4.2 sp_1.4.5
#> SparseM_1.81 splines_4.0.5 statmod_1.4.35
#> stats_4.0.5 stringi_1.5.3 stringr_1.4.0
#> svglite_2.0.0 sys_3.4 systemfonts_1.0.2
#> tibble_3.1.0 tidyr_1.1.3 tidyselect_1.1.0
#> tidyverse_1.3.1 tinytex_0.31 tools_4.0.5
#> utf8_1.2.1 utils_4.0.5 uuid_0.1.4
#> vctrs_0.3.7 viridisLite_0.3.0 webshot_0.5.2
#> withr_2.4.1 xfun_0.22 xml2_1.3.2
#> yaml_2.2.1 zip_2.1.1